package com.ncmmall.domain.business.order.aftersale;

import com.fasterxml.jackson.annotation.JsonBackReference;
import com.ncmmall.domain.business.order.OrderDetail;
import lombok.Getter;
import lombok.Setter;
import org.hibernate.annotations.NotFound;
import org.hibernate.annotations.NotFoundAction;

import javax.persistence.*;

/**
 * @author linxs
 * @Description: 售后订单详情
 * @Date: 2020-05-24 18:09
 */
@Entity
@Table(name = "mall_order_after_sale_detail")
@Access(AccessType.FIELD)
@Getter
@Setter
public class OrderAfterSaleDetail {

    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    private long id;

    @JsonBackReference
    @ManyToOne
    @JoinColumn(name = "after_sale_order_id")
    @NotFound(action = NotFoundAction.IGNORE)
    private OrderAfterSale afterSaleOrder;

    @OneToOne
    private OrderDetail orderDetail;




}
